/*
* $Id: JournalSettings.h 156 2010-09-28 19:00:52Z volok-aleksej@yandex.ru $
*
* Copyright 2008 by Volokitin Alexey
* All rights reserved
*
*/
#ifndef _JOURNAL_SETTINGS_H_
#define _JOURNAL_SETTINGS_H_

#include "../Setting.h"

interface IJournalComponent;
class CTypeTable;

class CJournalSettings : public CSettings
{
	IJournalComponent* m_pJournalComponents;
	std::map<std::tstring, int> m_aTypeHousing;
	std::map<std::tstring, int> m_aTypeFrame;
private:
	std::tstring SaveTypeList(Housing::change_type tp, const std::tstring& strState);
protected:
	virtual std::map<std::tstring, std::tstring> GetStates();
	virtual std::map<std::tstring, std::tstring> GetDefaultStates();
	virtual std::map<std::tstring, std::vector<Parameter> > GetParameters();
	virtual std::vector<Window> GetWindows();
	virtual void PostSave();
public:
	CJournalSettings(IJournalComponent* pJournalComponents);
	virtual ~CJournalSettings();
public:
	virtual std::tstring GetSaveValue(const std::tstring& strValueName, const std::tstring& strValue, bool& bSave);
	virtual void SetState(const std::tstring& strId, const std::tstring& strState);
	virtual void SaveSetting();
	virtual bool IsChanged();
};

#endif /*_JOURNAL_SETTINGS_H_*/